Skip to content

Refactor LabelNames to return model.LabelNames type for consistency#1850

Merged
bwplotka merged 2 commits into
prometheus:mainfrom
yshngg:bugfix/type-consistency
Aug 19, 2025
Merged

Refactor LabelNames to return model.LabelNames type for consistency#1850
bwplotka merged 2 commits into
prometheus:mainfrom
yshngg:bugfix/type-consistency

Conversation

@yshngg

@yshngg yshngg commented Jul 31, 2025

Copy link
Copy Markdown
Contributor

No description provided.

…or consistency

Signed-off-by: yshngg <yshngg@outlook.com>

@kakkoyun kakkoyun left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

yshngg added a commit to yshngg/prometheus-mcp-server that referenced this pull request Aug 1, 2025
```diff
-// TODO: replace []string with model.LabelNames ? prometheus/client_golang#1850
+// TODO: Replace []string with model.LabelNames (see prometheus/client_golang#1850).
```
yshngg added a commit to yshngg/prometheus-mcp-server that referenced this pull request Aug 1, 2025
* 💡(metadata_query): Add PR reference to TODO comment about LabelNames replacement
[Explanation: Added GitHub PR link (#1850) to existing TODO comment to provide context for future type replacement from []string to model.LabelNames]

* 💡(labels.go): Improve TODO comment clarity and formatting

```diff
-// TODO: replace []string with model.LabelNames ? prometheus/client_golang#1850
+// TODO: Replace []string with model.LabelNames (see prometheus/client_golang#1850).
```

@bwplotka bwplotka left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is breaking change, but API is still experimental, so LGTM, thanks!

@bwplotka bwplotka merged commit f48ff67 into prometheus:main Aug 19, 2025
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants